package fileLoader;
import org.hibernate.Session;

/**
 * 
 * class TagManager which is used to save, update or delete tag from data base
 *
 */
public class TagsManager {
 private Session session = null;
 public TagsManager(Session session) {
  if(session == null)
    throw new 
      RuntimeException("Invalid session object.");
  this.session = session;
 }
 public void saveTag(Tag tag){
  session.save(tag);
 }
 public void updateTag(Tag tag){
  session.update(tag);
 }
 public void deleteTag(Tag tag) {
  session.delete(tag);
 }
 
 
}